home *** CD-ROM | disk | FTP | other *** search
- // Ascii2Libr.h - autogenerated from Ascii2Libr.arg on Sat Apr 23 11:27:14 1994
- // Do not edit this file! Re-run makeargprc to re-generate
-
- #ifndef VERSION
- #define VERSION "V0.0"
- #endif
-
- class Ascii2Libr {
- public:
- Ascii2Libr(int argc,char** argv);
- void Usage();
- char* outfile; // Output file to create
- Boolean outfile_passed;
- int minpages; // Minimum number of pages to create file with.
- Boolean minpages_passed;
- };
-
- void Ascii2Libr::Usage()
- {
- cout << "Syntax: Ascii2Libr [opts]\n";
- cout << "Program to read the ASCII text file generated by Libr2Ascii\n";
- cout << "into a Librarian Card Catalog file\n";
- cout << "Options:\n";
- cout << "-outfile\tString Required Output file to create\n";
- cout << "-minpages\tInteger Optional Minimum number of pages to create file with.\n";
- cout << "\n\tVersion: " << VERSION << "\n"; cout << "\tCopyright (c) 1991,1992 Robert Heller D/B/A Deepwoods Software\n";}
-
- Ascii2Libr::Ascii2Libr(int argc,char** argv)
- {
- outfile_passed = false;
- minpages_passed = false;
- for (int iarg=1;iarg<argc;iarg++) {
- if (strcmp(argv[iarg],"-?") == 0 ||
- strcmp(argv[iarg],"-U") == 0) {
- Usage(); exit(0);
- } else if (strcmp(argv[iarg],"-outfile") == 0 && (iarg+1) < argc) {
- iarg++;
- outfile_passed = true;
- outfile = argv[iarg];
- } else if (strcmp(argv[iarg],"-minpages") == 0 && (iarg+1) < argc) {
- iarg++;
- minpages_passed = true;
- minpages = atoi(argv[iarg]);
- } else {
- cerr << "Bad option: " << argv[iarg] << "\n";
- Usage(); exit(1);
- }
- }
- if (!outfile_passed) {
- cerr << "Missing parameter: outfile\n";
- Usage(); exit(1);
- }
- }
-